<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>订单结算</title>
    <link href="https://cdn.bootcss.com/twitter-bootstrap/3.3.7/css/bootstrap.min.css" rel="stylesheet"> 
    <link href="../font-awesome/css/font-awesome.min.css" rel="stylesheet" type="text/css" />
    <link rel="stylesheet" href="../css/home.css">
    <link rel="stylesheet" href="../css/style.css">
    
    <script src="../js/jquery.min.js"></script>
    <script src="https://cdn.bootcss.com/twitter-bootstrap/3.3.7/js/bootstrap.min.js"></script>
</head>

<body class="page-container-bg-solid">
    <div class="page-header">
        <div class="page-header-top-nav">
            <div class="container">
                <div class="row">
                    <div class="col-md-6">
                        <a href="http://www.phpkaiyuancms.com" target="_blank">PHP开源CMS</a>
                        <span>|</span>
                        <a href="http://pos.com/">手机网站</a>
                        <span>|</span>
                        <a href="http://pos.com/index.php?s=member">会员中心</a>
                    </div>
                    <div class="col-md-6 text-right">
                        <div class="btn-group pull-right ">
                            <a class="" href="javascript:;" data-toggle="dropdown" data-hover="dropdown" data-close-others="true"> 网站导航
                                <i class="fa fa-angle-down"></i>
                            </a>
                            <ul class="dropdown-menu pull-right">
                                                                                        <li>
                                    <a href="/index.php?s=mall">商城</a>
                                </li>
                                                                                    </ul>
                        </div>
                        <div class="btn-group pull-right ">
                            <a class="" href="javascript:;" data-toggle="dropdown" data-hover="dropdown" data-close-others="true"> 快速发布
                                <i class="fa fa-angle-down"></i>
                                <span>|</span>
                            </a>
                            <ul class="dropdown-menu pull-right">
                                                            <li>
                                    <a href="http://pos.com/index.php?s=member&app=mall&c=home&m=add">商城</a>
                                </li>
                                                        </ul>
                        </div>
                        <div class="btn-group pull-right">
                            <a class="" href="javascript:;" data-toggle="dropdown" data-hover="dropdown" data-close-others="true"> 内容管理
                                <i class="fa fa-angle-down"></i>
                                <span>|</span>
                            </a>
                            <ul class="dropdown-menu pull-right">
                                                            <li>
                                    <a href="http://pos.com/index.php?s=member&app=mall&c=home&m=index">商城</a>
                                </li>
                                                        </ul>
                        </div>
                        <div class="btn-group pull-right ">
                            <a class="" href="javascript:;" data-toggle="dropdown" data-hover="dropdown" data-close-others="true"> 我的中心
                                <i class="fa fa-angle-down"></i>
                                <span>|</span>
                            </a>
                            <ul class="dropdown-menu pull-right">
                                <li>
                                    <a href="http://pos.com/index.php?s=member&c=account&m=index">资料修改</a>
                                </li>
                                <li>
                                    <a href="http://pos.com/index.php?s=member&c=account&m=avatar">上传头像</a>
                                </li>
                                <li>
                                    <a href="http://pos.com/index.php?s=member&c=account&m=password">修改密码</a>
                                </li>
                                <li class="divider"> </li>
                                <li>
                                    <a href="http://pos.com/index.php?s=member&c=pay&m=add">在线充值</a>
                                </li>
                                <li>
                                    <a href="http://pos.com/index.php?s=member&c=pay&m=index">财务流水</a>
                                </li>
                            </ul>
                        </div>
                        <div id="dr_member_info" class="pull-right">
                        </div>
                        <script type="text/javascript">
                            $.ajax({
                                type: "GET",
                                url:"http://pos.com/index.php?c=api&m=member&format=jsonp",
                                dataType: "jsonp",
                                success: function(json){
                                    $("#dr_member_info").html(json.html);
                                }
                            });
                        </script>
    
                    </div>
                </div>
            </div>
        </div>
        <div class="page-header-top">
            <div class="container">
                <div class="page-logo">
                    <a href="http://pos.com/">
                        <img src="http://pos.com/statics/default/pc/img/logo.png" alt="POSCMS" class="logo-default">
                    </a>
                </div>
    
                <div class="page-header-module">
                    订单频道
                                </div>
                <div class="page-header-search">
                    <form class="search-form" action="/index.php" method="get">
                        <input type="hidden" name="c" value="api">
                        <input type="hidden" name="m" value="search">
                        <input type="hidden" name="dir" id="dr_search_module_dir" >
                        <div class="input-group">
                            <div class="input-group-btn btn-group">
                                <button id="dr_search_module_name" type="button" class="btn default dropdown-toggle" data-toggle="dropdown" aria-expanded="false">
                                    <i class="fa fa-angle-down"></i>
                                </button>
                                <ul class="dropdown-menu">
                                    <!--这是来列出全部可以搜索的内容模块-->
                                                                                                                                    <li><a href="javascript:dr_search_module_select('mall', '商城');"> 商城 </a></li>
                                                                                                </ul>
                            </div>
                            <input type="text" placeholder="搜索内容..." name="keyword" class="fc-search-keyword form-control">
                            <div class="input-group-btn search-bttn">
                                <button class="btn default" type="submit"> <i class="fa fa-search"></i> </button>
                            </div>
                        </div>
                        <script>
                            // 这段js是用来执行搜索的
                            function dr_search_module_select(dir, name) {
                                $("#dr_search_module_dir").val(dir);
                                $("#dr_search_module_name").html(name+' <i class="fa fa-angle-down"></i>');
                            }
                            dr_search_module_select('order', '订单');
                        </script>
                    </form>
                </div>
                <div class="page-header-member">
                    <div class="btn-group pull-right">
                        <button type="button" class="btn green  dropdown-toggle" data-toggle="dropdown" aria-expanded="false">
                            <i class="fa fa-edit"></i>
                            免费发布信息
                        </button>
                        <ul class="dropdown-menu" role="menu">
                                                    <li>
                                <a href="http://pos.com/index.php?s=member&app=mall&c=home&m=add">商城</a>
                            </li>
                                                </ul>
                    </div>
                    <div class="pull-right hometel"> 028-62562781 </div>
                </div>
            </div>
        </div>
    
        <div class="page-header-menu">
            <div class="container">
    
                <!-- 调用网站栏目菜单 -->
                <div class="hor-menu  ">
                    <ul class="nav navbar-nav">
                        <li id="dr_nav_0" class="menu-dropdown classic-menu-dropdown ">
                            <a href="http://pos.com/" title="POSCMS程序">首页</a>
                        </li>
    
    
                        <!--第一层：调用栏目-->
                        
    
                        <!--调用所有独立模块-->
                                                                <li class="menu-dropdown classic-menu-dropdown ">
                            <a href="/index.php?s=mall" title="">商城</a>
                        </li>
                                            
                    </ul>
                </div>
            </div>
        </div>
        <!-- END HEADER MENU -->
    </div><script type="text/javascript">
    $(function(){
            dr_get_order_price();
            $('.online-payment').hover(function(){
            $(this).addClass('payment-item-hover');
        },function(){
            $(this).removeClass('payment-item-hover');
        });
        $(".payment-item").click(function(){
            var id = $(this).attr("pid");
            $(".payment-item").removeClass("default");
            $(".payment-item").addClass("grey-mint");
            $(this).addClass("default");
            // 赋值
            $("#dr_pay_type").val(id);
        });
    });
    function dr_get_order_price() {
        $.ajax({type: "POST", url: "http://pos.com/index.php?s=order&c=home&m=price&is_shipping=0&city="+$("#dr_shipping_city").val(), data: {data: {"mall_1_1":{"mid":"mall","uid":"1","price":100,"order_score":0,"url":"\/index.php?s=space&uid=1","name":"admin","username":"admin","buy_step":0,"goods":[{"id":"8","uid":"2","sell":"1","mid":"mall","cid":"1","quantity":1,"specification":"value2_value5","agent":"e2839533e4dcbc996ae80826df22b1c1","inputtime":"1566286783","url":"\/index.php?s=mall&c=show&id=1","title":"\u6d4b\u8bd5","catid":"1","thumb":"1","buy_step":0,"shipping":0,"shipping_param":{"m3":"","kg":""},"sn":"","sku":{"\u989c\u8272":"\u7ea2\u8272","\u5c3a\u7801":"X"},"order_score":0,"order_price":100,"order_quantity":997,"price":100,"use":1}]}}}, dataType:"json",
            success: function (data) {
                if (data.status == 1) {
                    $("#dr_total_price").html(data.price);
                    $("#dr_total_score").html(data.score);
                    $.each(data.info, function(n, value) {
                        $("#dr_order_yunfei_"+n).html(value.yunfei);				
                        $("#dr_order_youhui_"+n).html(value.youhui);
                        $("#dr_order_total_"+n).html(value.price);
                        $("#dr_order_total_score_"+n).html(value.score);
                    });
                } else {
                    dr_tips(data.code);
                }
            }
        });
    }
    function dr_load_address() {
        $("#dr_address_list").html('<img src="http://pos.com/statics/admin/images/loading-mini.gif" />');
        $.ajax({type: "GET", url: "http://pos.com/index.php?s=order&c=address&m=index&id="+$("#dr_shipping_id").val()+"&"+Math.random(), dataType:"jsonp",
            success: function (data) {
                $("#dr_address_list").html(data.html);
                // 重新计算运费和订单总额
                dr_get_order_price();
            }
        });
    }
    function dr_add_address() {
        var url = "http://pos.com/index.php?s=order&c=address&m=add";
        art.dialog.open(url, {title: "新增收货地址",
            ok: function () {
                var iframe = this.iframe.contentWindow;
                if (!iframe.document.body) {
                    alert('iframe loading')
                    return false;
                };
                var data = iframe.$('#myform').serialize();
                $.ajax({type: "GET", url:url, data:data+'&submit=1', dataType:'jsonp', success: function (data) {
                    if (data.status == 1) {
                        iframe.art.dialog.close();
                        dr_tips('添加成功', 3, 1);
                        dr_load_address();
                    } else {
                        dr_tips(data.code);
                    }
                }});
                return false;
            },
            cancel: true
        });
    }
    function dr_edit_address(id) {
        var url = "http://pos.com/index.php?s=order&c=address&m=edit&id="+id;
        art.dialog.open(url, {title: "修改收货地址",
            ok: function () {
                var iframe = this.iframe.contentWindow;
                if (!iframe.document.body) {
                    alert('iframe loading')
                    return false;
                };
                var data = iframe.$('#myform').serialize();
                $.ajax({type: "GET", url:url, data:data+'&submit=1', dataType:'jsonp', success: function (data) {
                    if (data.status == 1) {
                        dr_tips('修改成功', 3, 1);
                        iframe.art.dialog.close();
                        dr_load_address();
                    } else {
                        dr_tips(data.code);
                    }
                }});
                return false;
            },
            cancel: true
        });
    }
    function dr_del_address(id) {
        $.ajax({type: "GET", url:"http://pos.com/index.php?s=order&c=address&m=del&id="+id, dataType:'jsonp', success: function (data) {
            if (data.status == 1) {
                dr_tips('删除成功', 3, 1);
                dr_load_address();
            } else {
                dr_tips(data.code);
            }
        }});
    }
    function dr_set_address(id) {
        $.ajax({type: "GET", url:"http://pos.com/index.php?s=order&c=address&m=set_default&id="+id, dataType:'jsonp', success: function (data) {
            if (data.status == 1) {
                dr_tips('设置成功', 3, 1);
            } else {
                dr_tips(data.code);
            }
        }});
    }
    </script>
    
    <div class="page-container">
        <div class="page-content-wrapper">
            <div class="page-content bg-h">
                <div class="container">
    
                    <ul class="page-breadcrumb breadcrumb">
                        <li>
                            <a href="http://pos.com/">首页</a>
                            <i class="fa fa-angle-right"></i>
                        </li>
                        <li>
                            <a href="http://pos.com/index.php?s=order&c=cart&m=index">购物车</a>
                            <i class="fa fa-angle-right"></i>
                        </li>
                        <li>
                            <span>订单结算</span>
                        </li>
                    </ul>
    
                    <div class="stepBlock">
                        <h2 class="second"></h2>
                        <p class="stepTxt">
                            <span class="one selected">加入购物车</span>
                            <span class="two selected">确认订单内容</span>
                            <span class="three">成功提交并付款</span>
                            <span class="four">确认配送并评论</span>
                        </p>
                    </div>
    
                    <form action="" id="myform" method="post">
                        <div class="page-content-inner">
    
                            
                            <div class="portlet light">
                                <div class="portlet-title">
                                    <div class="caption">支付方式</div>
                                    <div class="actions">
                                    </div>
                                </div>
                                <div class="portlet-body">
                                    <input type="hidden" name="data[pay_type]" id="dr_pay_type" value="2">
                                                                    <a pid="2" class="btn  default payment-item online-payment" href="javascript:;">在线支付</a>
                                                                </div>
                            </div>
    
    
                                                    <div class="portlet light">
                                <div class="portlet-title">
                                    <div class="caption">商家：<a href="/index.php?s=space&uid=1" target="_blank">admin</a></div>
                                    <div class="actions">
                                    </div>
                                </div>
                                <div class="portlet-body">
                                    <div class="row">
                                                                            <div class="col-md-9 col-sm-12">
                                            <div class="media">
                                                <a class="pull-left" href="javascript:;">
                                                    <img src="http://pos.com/uploadfile/thumb/c4ca4238a0b923820dcc509a6f75849b/55-55-0-0.jpg" width="55" height="55">
                                                </a>
                                                <div class="media-body">
                                                    <h5 class="media-heading"><a href="/index.php?s=mall&c=show&id=1" target="_blank">测试</a></h5>
                                                                                                    <lable>颜色：红色&nbsp;&nbsp;</lable>
                                                                                                    <lable>尺码：X&nbsp;&nbsp;</lable>
                                                                                                    <lable>
                                                        x1                                                </lable>
                                                </div>
                                            </div>
                                        </div>
                                        <div class="col-md-3 text-right">
                                            <b class="font-red">￥100.00元</b>
                                        </div>
    
                                        <div class="col-md-8 col-sm-12" style="margin-top: 15px">
                                            <textarea placeholder="限45个字（定制类商品，请将购买需求在备注中做详细说明）" class="form-control" name="data[mall_1_1][buy_note]"></textarea>
                                                                                </div>
    
                                        
    
                                        <div class="col-md-4 col-sm-12 text-right" style="margin-top: 15px">
                                            运费：￥<span class="font-red" id="dr_order_yunfei_mall_1_1">0.00</span>元<br>
    
                                            店铺合计(含运费)：￥<span class="font-red" id="dr_order_total_mall_1_1">0.00</span>元   <span id="dr_order_total_score_mall_1_1">0</span>虚拟币                                    </div>
                                    </div>
                                </div>
                            </div>
                            
                            <div class="portlet light">
                                <div class="portlet-title">
                                    <div class="caption">合计</div>
                                    <div class="actions">
                                    </div>
                                </div>
                                <div class="portlet-body">
                                    <div class="row">
                                        <div class="col-md-6 col-sm-12 text-left">
                                            <lable>应付总额：<strong style="color: red">￥<span id="dr_total_price">0.00</span>元</strong>   <strong style="color: red"><span id="dr_total_score">0</span>虚拟币</strong></lable>
                                        </div>
                                        <div class="col-md-6 col-sm-12 text-right" >
                                            <lable><button  type="submit" class="btn btn-lg default"> <i class="fa fa-rmb"></i> 提交订单</button></lable>
                                        </div>
                                    </div>
                                </div>
                            </div>
    
    
                        </div>
                    </form>
                </div>
            </div>
        </div>
    </div>
    
    <div class="page-footer">
        <div class="container">
    
            <a href="http://www.phpkaiyuancms.com" target="_blank">POSCMS</a> v3.6.0
        </div>
    </div>
    <div class="scroll-to-top">
        <i class="fa fa-arrow-circle-up"></i>
    </div>
    
    </body>
    
</html>